#ifndef SGT_STYLE_HPP
#define SGT_STYLE_HPP

#include "qt_api.hpp"
//system global 
class SgtStyle{
public:
    enum SORT{
        GLOBAL=0,
    };
    SgtStyle();
    ~SgtStyle();
    bool get_style(QString& str,int sort);
    
    static SgtStyle* getInstance()
    {
        static std::mutex mutex;
        static SgtStyle* instance=nullptr;
        if(nullptr==instance)
        {
            std::lock_guard<std::mutex> lck(mutex);
            if(nullptr==instance)
            {
                instance = new SgtStyle();
            }
        }
        return instance;
    }

private:
    std::map<int,QString> style_map;

    void load_style(const QString path,int sort);
};

#endif